/************************************************************************
 *
 * libsim.h
 *
 * (c) Copyright 1996-2004 Analog Devices, Inc.  All rights reserved.
 * $Revision: 1.1 $
 ************************************************************************/

/* C header file for non-standard, user-callable routines in
 * TigerSharc libsim.so, libstub.s.
 */

#pragma once
#ifndef __NO_BUILTIN
#pragma system_header /* libsim.h */
#endif

#ifndef __LIBSIM_DEFINED
#define __LIBSIM_DEFINED

#ifdef __cplusplus
extern "C" {
#endif

int __print_sanity();
int __print_int(int);
int __print_uint(unsigned int);
int __print_fract(int);
int __print_float(float);
int __print_double(long double);
int __print_longlong(long long);
int __print_ulonglong(unsigned long long);

int  __emuclk(void); /* get simulator cycle count (clock) */
void __sprintf_bufsz(int _size); /* set internal sprintf buffer size */

typedef enum _LibTraceFlag_t {
  _TRACE_OFF   = 0,
  _TRACE_IFACE = 1, /* trace interface events */
  _TRACE_TRAPS = 2  /* trace TRAP service requests */
} _LibTraceFlag_t ;

int  __libsim_trace(int _trace_flags); /* enable/disable tracing */

#ifdef __cplusplus
}
#endif

#endif /* __LIBSIM_DEFINED */
